package com.jy.appmarket.network.engine;

import java.util.Map;

import com.jy.appmarket.network.resultdata.PageResult;

import android.content.Context;

/**
 * 类说明：
 * 
 * @author Toby.chen
 * @date 2013-6-3
 * @version 1.0
 */

public class DiscoveryNetEngine extends BaseNetEngine {
	private int mPage;
	private long mDataVersion;

	public DiscoveryNetEngine(long dataVersion, int page) {
		mResultData = new PageResult();
		mDataVersion = dataVersion;
		mPage = page;
	}

	@Override
	protected String getCommand() {
		return "discovery";
	}

	@Override
	protected void getParams(Context context, Map<String, String> custParams) {
		custParams.put("pageNo", String.valueOf(mPage));
		if (mDataVersion != 0) {
			custParams.put("dataVersion", String.valueOf(mDataVersion));
		}
	}

}
